package com.regentsoft.cloudback.enterpriseAdmin.entity;


import io.swagger.annotations.ApiModelProperty;

import java.io.Serializable;

public class ScreenMedia implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(notes = "企业id",hidden = true)
    private String companyId;

    /**
     * @备注:文件id
     * @字段:id int(10)
     */
    @ApiModelProperty(notes = "文件id",hidden = true)
    private Integer id;

    /**
     * @备注:文件类型：1图片 2视频
     * @字段:type int(10)
     */
    @ApiModelProperty(notes = "文件类型：1图片 2视频")
    private Integer type;

    /**
     * @备注:文件序号
     * @字段:fileNo int(10)
     */
    @ApiModelProperty(notes = "文件序号")
    private Integer fileNo;

    /**
     * @备注:文件名，带扩展名
     * @字段:fileName varchar(20)
     */
    @ApiModelProperty(notes = "文件名，带扩展名")
    private String fileName;

    @ApiModelProperty(notes = "显示给用户看的文件名")
    private String viewName;

    //文件大小
    @ApiModelProperty(notes = "文件大小，单位byte")
    private Long size;

    @ApiModelProperty(notes = "下载连接")
    private String downloadUrl;

    public ScreenMedia() {
    }

    public ScreenMedia(String companyId, Integer type, Integer fileNo, String fileName, Long size) {
        this.companyId = companyId;
        this.type = type;
        this.fileNo = fileNo;
        this.fileName = fileName;
        this.size = size;
    }

    public ScreenMedia(Integer id) {
        this.id = id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getId() {
        return this.id;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public Integer getType() {
        return this.type;
    }

    public void setFileNo(Integer fileNo) {
        this.fileNo = fileNo;
    }

    public Integer getFileNo() {
        return this.fileNo;
    }

    public void setFileName(String fileName) {
        this.fileName = fileName;
    }

    public String getFileName() {
        return this.fileName;
    }

    public Long getSize() {
        return size;
    }

    public void setSize(Long size) {
        this.size = size;
    }

    public String getCompanyId() {
        return companyId;
    }

    public void setCompanyId(String companyId) {
        this.companyId = companyId;
    }

    public String getDownloadUrl() {
        return downloadUrl;
    }

    public void setDownloadUrl(String downloadUrl) {
        this.downloadUrl = downloadUrl.concat("&companyId=").concat(companyId).concat("&fileName=").concat(fileName);
    }

    public void setViewUrl(String viewUrl){
        this.downloadUrl = viewUrl;
    }

    public String getViewName() {
        return viewName;
    }

    public void setViewName(String viewName) {
        this.viewName = viewName;
    }
}
